package com.wedo.mall.entity;

/**
 * Created by Lawrence on 2017/8/18.
 */

public class Address {

    /**
     * id : 2
     * pid : 1
     * region_name : 北京
     * true_name : 北京
     * level : 2
     * add_time : 0
     */

    public String id;
    public String pid;
    public String region_name;
    public String true_name;
    public String level;
    public String add_time;

    @Override
    public String toString() {
        return region_name;
    }

    @Override
    public boolean equals(Object o) {
        if (this == o) return true;
        if (!(o instanceof Address)) return false;

        Address address = (Address) o;

        if (!id.equals(address.id)) return false;
        return pid.equals(address.pid);
    }

    @Override
    public int hashCode() {
        int result = id.hashCode();
        result = 31 * result + pid.hashCode();
        return result;
    }
}
